![]() |
PATH![]() |
![]() ![]() |
Table A-12 summarizes the syntax for assigning values to variables and script properties and declaring local and global variables. For information about variables and script properties, see Values and Constants For detailed information about the scope of script variables and properties, see Scope of Script Variables and Properties.
Table A-12 Assignments and declarations
The Text Item Delimiters property, which is the only property you can get and set using the global variable AppleScript , consists of a list of the delimiters used by AppleScript when coercing lists to strings and when getting text items from strings. This property is declared by AppleScript and is available from any script. You can get and set this property with statements such as the following:
set savedDelimiters to AppleScript's text item delimiters
set AppleScript's text item delimiters to {":"}
get last text item of "Hard Disk:CD Contents:Release Notes"
--result: "Release Notes"
set AppleScript's text item delimiters to savedDelimiters
Currently, only the first delimiter in the list is used by AppleScript. For more information, see AppleScript Properties.